package com.caiyi.financial.nirvana.sms.api;

import com.caiyi.financial.nirvana.sms.param.SendMsgParam;
import com.youyu.common.api.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;

/**
 * Created by Mario on 2017/12/18 0018.
 * 发送短信Controller
 */
@Api(description = "发送短信接口")
@RequestMapping("/com/caiyi/financial/nirvana/sms/api/send")
@FeignClient(name = "sms-frontend")
public interface SmsMsgSendApi {


    /**
     * 发送短信接口
     *
     * @param sendMsgParam 参数
     * @return 结果短信批次id
     */
    @RequestMapping(value = "/message", method = RequestMethod.POST)
    @ApiOperation("发送短信")
    @ApiImplicitParam(name = "param", value = "短信接口参数", required = true, dataType = "SendMsgParam", paramType = "body")
    Result sendMsg(@RequestBody SendMsgParam sendMsgParam);
}
